﻿<%@ Page Language="C#" MasterPageFile="~/GUI/SiteMasterPage.Master" AutoEventWireup="true" CodeBehind="ViewDocument.aspx.cs" Inherits="wdss.GUI.ViewDocument" Title="View Document" %>
<asp:Content ID="Content2" ContentPlaceHolderID="content1" runat="server">
<br /><br />
    <table align =center>
	    <tr>
	    <td>
	    <asp:Label ID = welcome_lbl runat =server Font-Names = "Arial Rounded MT Bold" 
	    ForeColor ="white" Text="Welcome" Font-Size="20px"></asp:Label>
	    </td>
	    <td>
	    <asp:Label ID = username_lbl runat =server Font-Names = "Arial Rounded MT Bold" 
	    ForeColor ="white" Text="" Font-Size="20px"></asp:Label>
	    </td>
	    <td>
	    <asp:Label ID = sym_lbl runat =server Font-Names = "Arial Rounded MT Bold" 
	    ForeColor ="white" Text="...!" Font-Size="20px"></asp:Label>
	    </td>
	    </tr></table>
	    <br />
<form id="frmViewDocument">
    <div class="heading">
    <table align=center><tr><td>
        <asp:Label ID="Label1" runat="server"  Text="View Document" Font-Bold="True" 
        Font-Names="Arial Rounded MT Bold" Font-Size="XX-Large" ForeColor="White"></asp:Label>
        </td></tr></table>
    </div>
   
        
       
            <table align =center border = 2>
                <tr>
                    <td>
                        <asp:Label ID="lbl_ChooseDocument" runat="server" Text="Choose Document" AssociatedControlID="ddl_ChooseDocument"
                        ForeColor="White" Font-Names="Arial Rounded MT Bold"></asp:Label>
                    </td>
                    <td align="left">
                        <asp:DropDownList ID="ddl_ChooseDocument" runat="server" 
                            DataSourceID="wdm_authored_documents" DataTextField="doc_title" 
                            DataValueField="doc_id" Height="30px" Width="230px"></asp:DropDownList>
                        <asp:SqlDataSource ID="wdm_authored_documents" runat="server" 
                            ConnectionString="<%$ ConnectionStrings:aspnetdbConnectionString %>" 
                            SelectCommand="sp_GetViewDocuments" 
                            SelectCommandType="StoredProcedure" ProviderName="System.Data.SqlClient">
                            <SelectParameters>
                                <asp:SessionParameter DefaultValue="0" Name="par_userid" SessionField="userid" 
                                    Type="Int32" />
                            </SelectParameters>
                        </asp:SqlDataSource>
                    </td>
                </tr>
                <tr>
                <td colspan =2 align=right>
                <asp:Button ID="btn_View" runat="server" Text="View Document" BackColor="#14263A" 
                BorderStyle="Outset" Font-Names="Arial Rounded MT Bold" ForeColor="White"
                onclick="btn_View_Click"/>
                </td>
                </tr>
            </table>
            <div>
                <asp:Label id="lbl_Error" runat="server" Visible="false" ForeColor="Red"></asp:Label>   
            </div> 
            
       
    </form>
</asp:Content>

